conf = require("../config")
if not conf.dashboard.enabled then return {} end

return {
  "nvimdev/dashboard-nvim",
  event = 'VimEnter',
  dependencies = {{'nvim-tree/nvim-web-devicons'}},
  config = function ()
    require("dashboard").setup({
      theme = 'doom',
      config = {
        header = {
        '                                                       ',
        '                                                       ',
        '                                                       ',
        '                                                       ',
        '                                                       ',
        '                                                       ',
        '                                                       ',
        '                                                       ',
        '                                                       ',
        '                                                       ',
        ' ███╗   ██╗ ███████╗ ██████╗  ██╗   ██╗ ██╗ ███╗   ███╗',
        ' ████╗  ██║ ██╔════╝██╔═══██╗ ██║   ██║ ██║ ████╗ ████║',
        ' ██╔██╗ ██║ █████╗  ██║   ██║ ██║   ██║ ██║ ██╔████╔██║',
        ' ██║╚██╗██║ ██╔══╝  ██║   ██║ ╚██╗ ██╔╝ ██║ ██║╚██╔╝██║',
        ' ██║ ╚████║ ███████╗╚██████╔╝  ╚████╔╝  ██║ ██║ ╚═╝ ██║',
        ' ╚═╝  ╚═══╝ ╚══════╝ ╚═════╝    ╚═══╝   ╚═╝ ╚═╝     ╚═╝',
        '                                                       ',
        '                                                       ',
        '                                                       ',
        }, --your header
        center = {
          -- {
          --   icon = "  ",
          --   desc = 'Recently lastest session    ',
          --   action = ""
          -- },
          -- {
          --   icon = "  ",
          --   desc = "Recently opened files       ",
          --   action = ""
          -- },
          {
            icon = "  ",
            desc = "Recent Projects                ",
            action = "Telescope projects"
          },
          {
            icon = "  ",
            desc = "Find File                   ",
            action = "Telescope find_files"
          },
          -- {
          --   icon = "  ",
          --   desc = "File Browser                ",
          --   action = "Telescope app"
          -- },
          -- {
          --   icon = "  ",
          --   desc = "Find Word                   ",
          --   action = ""
          -- },
          {
            icon = "  ",
            desc = "Open Personal dotfiles      ",
            action = "edit $MYVIMRC"
          },
        },
        footer = {}  --your footer
      },
      hide = {
        statusline = true,
        tabline = true,
        winbar = true
      },
    })
  end,
}
